﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using Extentions;
using Microsoft.VisualStudio.TestTools.UnitTesting;

namespace TestProject
{
    [TestClass]
    public class BetweenTests
    {
        const double testValue = 5.0;

        [TestMethod]
        public void BetweenOpen()
        {
            Assert.IsFalse(testValue.BetweenOpen(0.0, 5.0));
            Assert.IsFalse(testValue.BetweenOpen(5.0, 10.0));
            Assert.IsTrue(testValue.BetweenOpen(4.99, 5.01));
        }

        [TestMethod]
        public void BetweenClose()
        {
            Assert.IsTrue(testValue.BetweenClosed(0.0, 5.0));
            Assert.IsTrue(testValue.BetweenClosed(5.0, 10.0));
            Assert.IsTrue(testValue.BetweenClosed(4.99, 5.01));
        }
    }
}
